num = (1,2,3,4)

for i in num:
    for j in num:
        for k in num:
            if i!=j and i!=k and j!=k:
                print(100*i+10*j+k)
